##https://blog.csdn.net/qq_37806908/article/details/97686753


clean:
	rm -rf *.o *.so *.out

com:
	gcc -c hello.c
	gcc -c main.c

slib:
	ar -cr libmyhello.a hello.o

gen0:
	gcc -o hello main.c -L. -lmyhello

gen1:
	gcc main.c libmyhello.a -o hello

gen2:
	gcc -o hello main.o libmyhello.a

dlib:
	gcc -shared -fPIC -o libmyhello.so hello.o

gen3:
	gcc -o hello main.c -L. -lmyhello


sall: clean com slib  gen0

dall: clean com dlib gen3


